package com.example.littleSpider.myapplication.fragment.findPartner;

import android.view.View;

import com.example.littleSpider.myapplication.R;
import com.example.littleSpider.myapplication.base.BaseFragment;

import java.util.List;

import butterknife.BindViews;
import butterknife.OnClick;

/**
 * Created by littleSpider on 2018/1/16.
 */

public class AllOfPartnerFragment extends BaseFragment {

    @BindViews({R.id.view_latest, R.id.view_charm, R.id.view_focus_on})
    List<View> indictorViews;

    @Override
    protected int setLayout() {
        return R.layout.fragment_all_of_partner;
    }

    @Override
    protected void initView() {

    }

    @Override
    protected void initData() {

    }

    @OnClick({R.id.rl_latest, R.id.rl_charm, R.id.rl_focus_on})
    public void changeType(View view){
        for(View indictor : indictorViews){
            indictor.setVisibility(View.GONE);
        }
        int chooseNum;
        switch (view.getId()){
            case R.id.rl_latest:
                chooseNum = 0;
                break;
            case R.id.rl_charm:
                chooseNum = 1;
                break;
            case R.id.rl_focus_on:
                chooseNum = 2;
                break;
            default:
                chooseNum = 0;
                break;
        }
        indictorViews.get(chooseNum).setVisibility(View.VISIBLE);
    }

}
